# len()统计字符串长度
# str1 = 'woaini'
# print(len(str1))


# 不使用len()统计字符串长度

# str1 = 'nisk'
# count = 0
# for i in str1:
#     count+=1
# print(f'字符串的长度是{count}')
#
# count = 0
# for i in str2:
#     count+=1
# print(f'字符串的长度是{count}')
#
#
# count = 0
# for i in str3:
#     count+=1
# print(f'字符串的长度是{count}')

# str1 = 'Hello'
# str2 = 'World'
# str3 = 'aini'
#
# def my_length(data):
#     count = 0
#     for i in data:
#         count+=1
#     print(f'字符串{data}的长度是{count}')
#
#
# my_length(str1)
# my_length(str2)
# my_length(str3)





